package com.ruoyi.web.controller.gis;

import com.ruoyi.base.domain.BusWarnWarninfo;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.gis.domain.leaderCockpitVo;
import com.ruoyi.gis.service.LeaderCockpitService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/gis/leaderCockpit")
public class LeaderCockpitController extends BaseController {
    @Autowired
    private LeaderCockpitService leaderCockpitService;

    /**
     * 自动站水质状况
     */
    @GetMapping("/autoWaterQuality")
    public AjaxResult getAutoWaterQuality(leaderCockpitVo vo) {
        List<Map<String,Object>> list=leaderCockpitService.getWaterQuality(vo);

        return success(list);
    }
    /**
     * 手工站水质状况
     */
    @GetMapping("/manualWaterQuality")
    public AjaxResult getManualWaterQuality(leaderCockpitVo vo) {
        Map<String,Object> map=leaderCockpitService.getManualWaterQuality(vo);

        return success(map);
    }

    /**
     * 手工断面水质变化分析
     */
    @GetMapping("/manualSegmentDateChange")
    public AjaxResult getManualSegmentDateChange(leaderCockpitVo vo) {
        Map<String,Object> map=leaderCockpitService.getManualSegmentDateChange(vo);

        return success(map);
    }


    /**
     *最新预警信息
     */
    @GetMapping("/getWarningLastInfo")
    public AjaxResult getWarningLastInfo(leaderCockpitVo vo) {
        List<BusWarnWarninfo> list=leaderCockpitService.getWarningLastInfo(vo);
        return success(list);
    }

    /**
     * 预警统计
     */
    @GetMapping("/getWarningStatistics")
    public AjaxResult getWarningStatistics(leaderCockpitVo vo) {
        Map<String,Object> map=leaderCockpitService.getWarningStatistics(vo);
        return success(map);
    }
    /**
     * 污染源分析
     */
    @GetMapping("/pollutionSourceAnalysis")
    public AjaxResult getPollutionSourceAnalysis(leaderCockpitVo vo) {
        Map<String,Object> map=leaderCockpitService.getPollutionSourceAnalysis(vo);
        return success(map);
    }



}
